CONFIGURATION
https://prometheus.io/docs/prometheus/latest/configuration/configuration/#configuration

STORAGE
https://prometheus.io/docs/prometheus/latest/storage/


 Docker-Composeversion: "3.5"
services:
 prometheus:
   image: prom/prometheus:latest
   command:
      - "--config.file=/etc/prometheus/prometheus.yml"
      - "--storage.tsdb.path=/prometheus"
      - "--storage.tsdb.retention.time=7d"
   volumes:
      - "./prometheus.yml:/etc/prometheus/prometheus.yml"
      - "./PrometheusData:/prometheus"
   ports:
     # Web UI
      - "9090:9090"
   user: "<user with permission to volume path>"
 
  

 

Теги: